#!/usr/bin/perl
use strict;
package csuptime;
sub csuptime {
    my $secs = shift;
    my $csnum = shift;
    my $remote = shift;
    my $tonum = shift;
    my $secs = time - $secs;
 
    my $mins = 0; my $hours = 0; my $days = 0; 
    $mins = int($secs / 60);
    $secs = int($secs % 60);
    $hours = int($mins / 60);
    $mins = int($mins % 60);
    $days = int($hours / 24);
    $hours = int($hours % 24);

print $remote "$csnum O $tonum :Uptime For CSWorld IRC Services - $days days, $hours hours, $mins minutes and $secs seconds.\n";
    undef $mins,$hours,$days,$secs;
}
1;
